Generate po-properties/POTFILES at configure time. Patch by Loïc Minier
authorMatthias Clasen <matthiasc@src.gnome.org>
Sun, 1 Mar 2009 07:24:28 +0000 (07:24 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Sun, 1 Mar 2009 07:24:28 +0000 (07:24 +0000)
        * configure.in: Generate po-properties/POTFILES at configure time.
        Patch by Loïc Minier

svn path=/trunk/; revision=22430

ChangeLog
configure.in

index d1bd1b2d0e8d2ae8499fe269e240195fe79f9c95..0c8e815cf594eaf26668be83ebc422552c3c9586 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2009-03-01  Matthias Clasen  <mclasen@redhat.com>
+
+       Bug 573515 – po-properties/ special Makefile.in.in handling causes
+       failure to build
+
+       * configure.in: Generate po-properties/POTFILES at configure time.
+       Patch by Loïc Minier
+
 2009-03-01  Matthias Clasen  <mclasen@redhat.com>
 
        * demos/gtk-demo/appwindow.c: Set the program-name property
index a933ffe99808027e3d9783fa3fcd231f54e0bbf9..51bc4331e1796cbe6d8b58bc0456ada54dda2e73 100644 (file)
@@ -504,6 +504,26 @@ AC_OUTPUT_COMMANDS([case "$CONFIG_FILES" in *po-properties/Makefile.in*)
         sed -e "/POTFILES =/r po-properties/POTFILES" po-properties/Makefile.in > po-properties/Makefile
       esac])
 
+dnl Snippet below is copied from AM_GLIB_GNU_GETTEXT to generate a first
+dnl po-properties/POTFILES during configure; see GNOME #573515.
+dnl
+dnl Generate list of files to be processed by xgettext which will
+dnl be included in po-properties/Makefile.
+test -d po-properties || mkdir po-properties
+if test "x$srcdir" != "x."; then
+  if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
+    popropsrcprefix="$srcdir/"
+  else
+    popropsrcprefix="../$srcdir/"
+  fi
+else
+  popropsrcprefix="../"
+fi
+rm -f po-properties/POTFILES
+sed -e "/^#/d" -e "/^\$/d" -e "s,.*,   $popropsrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
+< $srcdir/po-properties/POTFILES.in > po-properties/POTFILES
+dnl (End of adapted AM_GLIB_GNU_GETTEXT snippet.)
+
 AM_GLIB_DEFINE_LOCALEDIR(GTK_LOCALEDIR)
 
 dnl The DU4 header files don't provide library prototypes unless